cmake_minimum_required(VERSION 2.8)

#include_directories(${PROTOBUF_INCLUDE_DIRS})
#include_directories(${CMAKE_CURRENT_BINARY_DIR})
#include_directories(${CMAKE_CURRENT_SOURCE_DIR})
#include_directories(${CMAKE_SOURCE_DIR}/src)

set(SOURCES
	../../src/core/tagreaderclient.cpp
)

set(HEADERS
	../../src/core/tagreaderclient.h
)

set(INCLUDE_DIRS
	../../src
    ../../src/core
	../../bin/src
    ../../bin/ext/libclementine-tagreader
    ../../ext/libclementine-common
)

include_directories(${INCLUDE_DIRS})

link_directories(
	../../../bin/ext/libclementine-tagreader
    ../../../bin/ext/libclementine-common
)

find_package(Qt4 REQUIRED)
#find_package(Protobuf REQUIRED)

SET(QT_USE_QTNETWORK TRUE)

INCLUDE(${QT_USE_FILE})

qt4_wrap_cpp(MOC ${HEADERS})

#find_library(PROTOBUF_LITE_LIBRARY protobuf-lite)

add_library(clementine-tagreaderclient SHARED
  ${SOURCES}
  ${MOC}
)

target_link_libraries(clementine-tagreaderclient
#  ${PROTOBUF_LITE_LIBRARY}
  libclementine-common
  libclementine-tagreader
)


#target_link_libraries(clementine-tagreader
#  ${TAGLIB_LIBRARIES}
#  ${QT_QTCORE_LIBRARY}
#  ${QT_QTNETWORK_LIBRARY}
#  libclementine-common
#  libclementine-tagreader
#)
#
#if(APPLE)
#  target_link_libraries(clementine-tagreader
#    /System/Library/Frameworks/Foundation.framework
#  )
#endif(APPLE)
#
#if(NOT APPLE)
#  # macdeploy.py takes care of this on mac
#  install(TARGETS clementine-tagreader
#          RUNTIME DESTINATION bin
#  )
#endif(NOT APPLE)


